package com.czh.mock.result;

import java.util.function.Function;

/**
 * 接收mock参数，用于生成mock数据
 *
 * @param <T> mock算法的参数
 * @param <R> mock算法的返回值
 */
class FieldSegment<T, R> {
    private String column;
    private T param;
    private Function<T, R> mockAlgorithm;

    public FieldSegment(String column, T param, Function<T, R> mockAlgorithm) {
        this.column = column;
        this.param = param;
        this.mockAlgorithm = mockAlgorithm;
    }

    public String getColumn() {
        return column;
    }

    public T getParam() {
        return param;
    }

    public Function<T, R> getMockAlgorithm() {
        return mockAlgorithm;
    }
}
